package com.bright.cwduijie.duijie.pojo.po;

import lombok.*;
import org.hibernate.Hibernate;
import org.hibernate.validator.constraints.Length;

import javax.persistence.*;
import javax.validation.constraints.NotBlank;
import java.io.Serializable;
import java.util.Objects;

/**
 * @Author  hxj
 * @Date 2024-07-11 10:08:31 
 * @Description  
 */

@Getter
@Setter
@ToString
@RequiredArgsConstructor
@Entity
@Table(name ="DJ_ZTYJ")
public class MonthlySettlement implements Serializable {

	private static final long serialVersionUID =  4152790841946396525L;

	@Id
	@GeneratedValue(strategy = GenerationType.IDENTITY)
   	@Column(name = "id")
	private Integer id;

	@NotBlank
	@Length(max = 36)
   	@Column(name = "ZT_DATA_KEY")
	private String ZT_DATA_KEY;

	@NotBlank
	@Length(max = 18)
   	@Column(name = "TYSHXYDM")
	private String TYSHXYDM;

	@NotBlank
	@Length(max = 6)
   	@Column(name = "KJQJ")
	private String KJQJ;

   	@Column(name = "djflag")
	private Boolean djflag;

   	@Column(name = "opType")
	private Integer opType;

   	@Column(name = "sjjhbz")
	private Integer sjjhbz;

   	@Column(name = "taskId")
	private String taskId;


	@Override
	public boolean equals(Object o) {
		if (this == o) return true;
		if (o == null || Hibernate.getClass(this) != Hibernate.getClass(o)) return false;
		MonthlySettlement that = (MonthlySettlement) o;
		return id != null && Objects.equals(id, that.id);
	}

	@Override
	public int hashCode() {
		return getClass().hashCode();
	}
}
